import matplotlib.pyplot as plt
import numpy as np
import pandas as pd

plt.rcParams['font.sans-serif'] = ['MicroSoft YaHei']

df = pd.read_table("./result/part-r-00000", names=['time', 'type', 'ds_id', 'value', 'dev_id'])
x = (df['time'] / 3600000 % 24 + 8) % 24
y = df['value']
numCount = x.count()
rng = np.random.RandomState(0)
colors = rng.rand(numCount)
# sizes = 100 * rng.rand(numCount)
plt.scatter(x, y, c=colors)
plt.xticks(np.arange(24))
plt.show()
